package com.gui.windows;

import javax.swing.JFrame;

import org.jdesktop.layout.GroupLayout;

public abstract class FrameWindow extends JFrame{

	public FrameWindow(String name) {
		super(name);
	}
	
	private static final long serialVersionUID = 1L;

	/** The main window layout */
	GroupLayout layout;
	
	/**
	 * Initialize all the components that are going to be contained by the main window.
	 * */
	protected abstract void initComponents ();

	/**
	 * Adds the components to the main window.
	 * */
	protected abstract void addComponents();
	
	/**
	 * Sets the layout of the main window.
	 * */
	protected void setLayout() {
		layout = new GroupLayout(this.getContentPane());
		this.getContentPane().setLayout(layout);
		layout.setAutocreateGaps(true);
		layout.setAutocreateContainerGaps(true);
	}
	
}
